package com.translate.web.param;

import java.util.List;

import javax.validation.Valid;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import com.translate.web.constant.ValidateCondtionAndMessage;
import com.translate.web.param.contract.IContractAddParam;


public class ContractAddParam<Data> implements IContractAddParam<Data> {// 合同名称
	@NotNull
	@Pattern(regexp = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION, message = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION_MSG)
	private String name;
	// 客户ID
	@NotNull
	@Min(value = ValidateCondtionAndMessage.MIN_ID, message = ValidateCondtionAndMessage.MIN_ID_MSG)
	private Integer customerId;
	// 订单id
	@NotNull
	@Min(value = ValidateCondtionAndMessage.MIN_ID, message = ValidateCondtionAndMessage.MIN_ID_MSG)
	private Integer orderId;

	// 创建人ID
	private Integer createUserId;
	// 合同编号
	@NotNull
	@Pattern(regexp = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION, message = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION_MSG)
	private String num;
	// 开始时间
	@NotNull
	@Min(value = ValidateCondtionAndMessage.MIN_ID, message = ValidateCondtionAndMessage.MIN_ID_MSG)
	private Long startTime;
	// 结束时间
	@NotNull
	@Min(value = ValidateCondtionAndMessage.MIN_ID, message = ValidateCondtionAndMessage.MIN_ID_MSG)
	private Long endTime;
	// 备注
	@NotNull
	@Pattern(regexp = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION, message = ValidateCondtionAndMessage.CHINESE_ENGLISH_NUMBER_UNDERLINE_BY_SERIESDESCRIPTION_MSG)
	private String remark;

	
	private List<@Valid Data> data;
	
	public List<Data> getData() {
		return data;
	}

	public void setData(List<Data> data) {
		this.data = data;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name == null ? null : name.trim();
	}

	public Integer getCustomerId() {
		return customerId;
	}

	public void setCustomerId(Integer customerId) {
		this.customerId = customerId;
	}

	public Integer getOrderId() {
		return orderId;
	}

	public void setOrderId(Integer orderId) {
		this.orderId = orderId;
	}

	public Integer getCreateUserId() {
		return createUserId;
	}

	public void setCreateUserId(Integer createUserId) {
		this.createUserId = createUserId;
	}

	public String getNum() {
		return num;
	}

	public void setNum(String num) {
		this.num = num == null ? null : num.trim();
	}

	public Long getStartTime() {
		return startTime;
	}

	public void setStartTime(Long startTime) {
		this.startTime = startTime;
	}

	public Long getEndTime() {
		return endTime;
	}

	public void setEndTime(Long endTime) {
		this.endTime = endTime;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark == null ? null : remark.trim();
	}

}